import {
    Server
} from "./http"
const getBaner = () => {
    let data = Server.get('/index-infos')
    return data
}
const poszhu = (obj) => {
    let data = Server.post('/user/register', {
        loginName: obj.loginName.value,
        password: obj.password.value,
    })
    return data
}
const LOGIN = (obj) => {

    let data = Server.post('/user/login', {
        loginName: obj.loginName.value,
        passwordMd5: obj.password.value
    })
    return data
}
const userinfo = (obj) => {

        let data = Server.get('user/info')
        return data
    }
    // 详情
const detail = (msg) => {
    let data = Server.get(`goods/detail/${msg}`)
    return data
}
const address = (msg) => {
    let data = Server.post("/address", msg)

    return data
}
const addressz = (msg) => {
    let data = Server.get("/address")

    return data
}
export {
    getBaner,
    poszhu,
    LOGIN,
    userinfo,
    detail,
    address,
    addressz
}